<%include ../common/include_header1.html%>

            <div class="cont">
            	<%include menu.html%>
            <div class="right">
                 <div class="lj">
                    <a href="/index.html"><img src="/web/images/tb6.png"></a> |
                    <a href="#"></a><a href="/index.html">首页</a>&gt; <a href="/company_dynamic/dynamic">招贤纳士</a> &gt; <a href="javascript:void(0)" id="mtitle">招聘信息</a>
                    <!-- <a href="#">企业简介</a> -->
                </div>
                <div class="right_nr">
                    <div class="pp"><img src="/web/images/tb11.png"></div>
                    <div class="yingpin">
                      <!--   <p>请您填写以下联系方式，并上传简历；您所提交的简历，我们审核资料后会电话通知您面试。</p> -->
                        <form id="form" name="thisform">
                        <div class="msgAddText">
                            <ul>
                                <li>
                                    <span>姓名：</span>
                                    <input type="text" name="luser" id="name" value="" class="moduleInputa">
                                </li>
                                <li>
                                    <span>E-mail：</span>
                                    <input type="text" name="lemail" id="email" value="" class="moduleInput">
                                </li>
                                <li>
                                    <span>联系方式：</span>
                                    <input type="text" name="cellphone" id="conact" value="" class="moduleInput">
                                </li>
                         <!--         <li>
                                    <span>简历：</span><iframe src="../../nnboxsin/funs/uploade.php" width="600" height="35" scrolling="auto" frameborder="0"></iframe>
                                    <input type="hidden" name="uploade">
                                </li> -->
                                <li>
                                    <span>内容：</span>
                                    <textarea name="lcontent" id="content" rows="10"></textarea>
                                </li>
                                <li>
                                  <span>验证码：</span>
                                  <!--图片验证码，点击图片实现刷新-->
              <input type="text" name="captcha" id="captcha" autocomplete="off" placeholder="请输入验证码" class="moduleInput" style="width:92px">
              <img src="/captcha"  style="width: 40%;height: 38px;vertical-align:top;cursor:pointer" onclick="this.src='/captcha?d='+Math.random();">
                                </li>
                                <li>
                                    <input id="submitForm" type="button" value="提交" class="ModuleSubmitButton">
                                </li>
                            </ul>   
                        </div></form>
                    </div>
                </div>
            </div>
            <div class="clear"></div>
            <style type="text/css">
            	.page{    text-align: center;
    font-size: 14px;
    margin: 40px 30px;}
            	.page a{    color: #000;
    border: 1px solid #ededed;
    background: #fbfcfb;
    padding: 5px 10px;margin-left: 4px;}
    .page a:hover {
    color: #f00000;
}
.layui-laypage-curr{  color: #000;
    border: 1px solid #ededed;
    background: #fbfcfb;
    padding: 5px 10px;}
    .layui-laypage-curr em{font-style: normal;}
    .layui-laypage-curr em:hover{color: #f00000;}
            </style>
        </div>
<script type="text/javascript" src="/web/layui/layui.js"></script>
<script>
    //一般直接写在一个js文件中
    layui.use(['layer', 'laypage','form'], function(){
        var layer = layui.layer
                ,laypage = layui.laypage
                , $ = layui.jquery;
        //页面初始化的时候执行
        $(function (){
            $("#news").addClass("active");
           //第一个参数：多少页，第二个参数，新闻类型，0企业动态，1媒体报道，2活动报道
           
          
            
        });
      $("#submitForm").click(function(){
        var name=$("#name").val().trim();
        var email=$("#email").val().trim();
        var conact=$("#conact").val().trim();
        var content=$("#content").val().trim();
        var myDate=new Date();
        var month=myDate.getMonth()+1;
        month=month<10?"0"+month:month;
        var date=myDate.getDate()<10?"0"+myDate.getDate():myDate.getDate();
        var hour=myDate.getHours()<10?"0"+myDate.getHours():myDate.getHours();
        var minutes=myDate.getMinutes()<10?"0"+myDate.getMinutes():myDate.getMinutes();
        var time=myDate.getFullYear()+"-"+month+"-"+date+" "+hour+":"+minutes;
        console.log({name:name,email:email,conact:conact,content:content,time:time})
        var captcha=$("#captcha").val().trim()
        if(name==""&&email==""&&conact==""&&content==""&&captcha==""){
          layer.alert("所有信息不能为空")
          return false;
        }
        if(name.length>20&&email.length>20&&conact.length>20){
          layer.alert("除内容外不能超过20个字")
          return false;
        }
        if(content.length>300){
          layer.alert("内容不能超过300个字")
          return false;
        }
            $.post("/submit_information",
            {name:name,email:email,conact:conact,content:content,time:time,captcha:captcha},
            function(result){
              if(result.status!="success"){
                layer.alert("验证码错误",{},function(){
                  layer.closeAll()
              })
                  return false;
              }
              layer.alert("发送成功",{},function(){
                location.reload()
              })
              
              });
      })
    });
</script>
<%include ../common/include_footer1.html%>
    

  